import { UserInfo } from '../login/type'
/**
 *  当前餐段与时间信息
 */
// export type NowInfo = PubliceInfo & {
//   data?: NowData
// }

/**
 *@param date 日期
 *@param mealTime 餐次
 *@param weeks_time 星期数
 */
export interface NowInfo {
  date: string
  mealTime: number
  weeks_time: string
}

/**
 *  菜肴列表
 * */
export type DishType = {
  data?: DishesInfo[]
}

/**
 * @param dishCode 菜肴编码
 * @param dishName 菜肴名称
 * @param dishType 菜肴类型
 * @param dishUrl 菜肴图片地址
 */
export interface DishesInfo {
  cook?: null | any
  dishAppearance?: number
  dishCode?: number
  dishFlavor?: number
  dishMaterial?: number
  dishName?: string
  dishStar?: number
  dishEvaluateFlag?: number
  dishType?: string
  dishUrl?: string
  eatDate?: string
  mealTime?: number
  recipeAbstract?: null
  recipeId?: number
  recipedtlId?: number
  res?: number
  sign?: number
  weight?: number
  flg?: number
  weeksTime?: string
  style?: number
}

/**
 * 所有食堂列表
 */

export type KitchenType = {
  data?: {
    unitCode?: string
    unitName?: string
  }
}

/**
 * 就餐预定数据
 * @param breakfast 每天早餐状态
 * @param breakfastSum 每天早餐预定人数
 * @param lunch 每天中餐状态
 * @param lunchSum 每天中餐预定人数
 * @param dinner 每天晚餐状态
 * @param lunchSum 每天晚餐预定人数
 *
 */

export type PepastType = {
  mealList?: PepastInfo[]
}
export interface PepastInfo {
  breakfast?: number
  breakfastSum?: number
  dinner?: number
  dinnerSum?: number
  eatDate?: string
  kitchenId?: number
  lunch?: number
  lunchSum?: number
  startBreakfast?: number
  startDinner?: number
  startLunch?: number
}

/**
 * @returns 历史食谱信息
 * @param data.beginTime 开始时间
 * @param data.endTime 结束时间
 * @param data.recipeName 食谱名称
 * @param data.kitchenId 食堂id
 * @param data.recipePeople 食堂人数
 */
export interface HistoryRecipe {
  beginTime?: string
  checkStatus?: string
  endTime?: string
  establishTime?: string
  foodOven?: string
  heat?: number
  kitchenId?: number
  recipeCode?: string
  recipeId?: number
  recipeName?: string
  recipePeople?: number
  sign?: boolean
  recipedtls?: string
}

/**
 * @returns 伙食问卷信息
 * @param questionn.createTime  问卷创建时间
 * @param questionn.id  问卷id
 * @param questionn.name  问卷名称
 */
export type QuestionnaireType = {
  questionn?: {
    createTime: string
    des: string
    id: string | number
    name: string
  }
  surveys?: surveysInfo[]
}

/**
 * @param radio 是否单选
 */
interface surveysInfo {
  qid?: number
  radio?: number
  sign?: number
  surveyId?: number
  topicContent?: string
  optionBoxs: optionInfo[]
}

interface optionInfo {
  optionContent?: string
  optionId?: number
  surveyId?: number
}

/**
 * @returns 就餐评议信息
 */

export interface AdviceInfo {
  adviceId: number
  advicePeople: string
  adviceTime: string
  attent: number
  content: string
  cook: null
  cookId: number
  dishName: null
  disposeContent: null
  disposeTime: null
  foodOven: null
  kitchenId: number
  kitchenName: null
  picture: string
  recipedtl: null
  recipedtlId: number
  tagsNumber: number
  targ: string
  userId: number
  user: UserInfo
}

/**
 * @returns 就餐建议信息
 */

export interface commnAdviceInfo {
  cont: string
  id: number
  seq: number
  sign: number
}

/**
 * 菜品详情
 */

export interface dishInfo {
  allChoose: number
  allFollow: number
  allReview: number
  attent: number
  describes: string
  dishAppearance: number
  dishCode: string
  dishFlavor: number
  dishId: number
  dishMaterial: number
  dishName: string
  dishStar: number
  dishType: string
  dishUrl: string
  establishTime: string
  flg: number
  newType: null
  style: null
}

export type dishesHotType = {
  dishes: dishInfo[]
  kitchenName: string
}
/**
 * 菜肴评价
 */
export interface Complain  {
  anonymous: number
dishAppearance: number
dishFlavor: number
dishMaterial: number
evaluateDocument: string
kitchenId: number
recipedtlId: string
score: number
userId: number
wordage: string
}
